from core.mcp import mcp
from sg.sg import (
    get_applications_count,
    get_models_count,
    get_users_count,
    get_tools_count,
    get_applications_count_by_tenant
)
from mindmap.mindmap import mindmap_tool

from core.mcp import mcp
import asyncio

# 先获取 tools（同步方式）
def print_registered_tools():
    tools = asyncio.run(mcp.get_tools())
    print("🔧 当前已注册工具:", tools)

if __name__ == "__main__":
    print_registered_tools()
    
    # 启动服务器
    mcp.run(transport='sse', host="0.0.0.0", port=8001)  # 可修改端口